package 单无人机架次;

import GA_Test.GAData;
import 多无人机架次.Node;


import java.util.ArrayList;
import java.util.HashSet;
import java.util.Set;

public class Print {
    public static void print(ArrayList<Object> truck,ArrayList<Object> drone){

        Set<Integer> set = new HashSet<>();
        for(int i = 0;i<truck.size();i++){
            ArrayList<Integer> al = (ArrayList<Integer>) truck.get(i);
            System.out.print("车辆" + (i+1) + "线路为");
            for( Integer in : al){
                System.out.print(in + " ");
                set.add(in);

            }
            System.out.println();
        }
        for(int i = 0;i<drone.size();i++){
            ArrayList<Integer> al = (ArrayList<Integer>) drone.get(i);
            System.out.print("无人机"+ (i+1)  + "线路为");
            for( Integer in : al){
                System.out.print(in+" ");
                set.add(in);
            }
            System.out.println();
        }
        System.out.println("待访问顾客数目为"+(GAData.cusInfo.length-2) + "访问顾客数目为：" + set.size()); //这里-2的原因 1是因为0点没有算 2是 第一行的标题行不算
    }
}
